using System;
using System.Collections.Generic;
using Dict.DataModel;

namespace Dict.Dao
{
    public class TableWallDao:DaoBase<TableWall>
    {
        public override void AddPrimaryIndex(TableWall model)
        {
            cachePrimary[model.MissionID.ToString()] = model;
        }

        public override string GetFileName()
        {
            return "TableWall.txt";
        }

        protected override TableWall ParseRowData(string[] rowData)
        {
            TableWall data = new TableWall();
			data.MissionID = rowData [0];
			data.MapId = rowData [1];
			data.OpenStr = rowData [2];

            return data;
        }


        public override void AddOneIndex(TableWall model)
        {
            if (!cacheOneIndex.ContainsKey(model.MapId.ToString()))
            {
                cacheOneIndex[model.MapId.ToString()] = new List<TableWall>();
            }
            cacheOneIndex[model.MapId.ToString()].Add(model);
        }
    

    }

}
